<template>
  <el-input
    v-if="model"
    class="modelxj"
    v-model="model[data.fieldId]"
    :placeholder="data.placeholder"
    :prefix-icon="data.setting.prefixIcon"
    :suffix-icon="data.setting.suffixIcon"
  ></el-input>
  <el-input
    v-else
    class="nomodel"
    v-model="data.value"
    :placeholder="data.placeholder"
    :prefix-icon="data.setting.prefixIcon"
    :suffix-icon="data.setting.suffixIcon"
  ></el-input>
</template>

<script>
export default {
  name: 'XueInput',
  props: {
    data: {
      type: Object,
      required: true,
    },
    model: Object,
  },
  mounted() {
    console.log(this.model)
  },
}
</script>
